package com.wuhuiyue.service.impl;

import com.wuhuiyue.entity.Log;
import com.wuhuiyue.mapper.LogMapper;
import com.wuhuiyue.service.ILogService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author hy-woo
 * @since 2022-06-14
 */
@Service
public class LogServiceImpl extends ServiceImpl<LogMapper, Log> implements ILogService {


    @Autowired
    LogMapper logMapper;
    @Override
    public void saveLog(Log log) {
        System.out.println("---------");
        try {
            Thread.sleep(5000);
            logMapper.insert(log);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        System.out.println("++++++++++");
    }
}
